Correct Memory Management for [string UTF8String]
Posted
by madmik3
on Stack Overflow
See other posts from Stack Overflow
or by madmik3
Published on 2010-04-29T20:29:49Z
Indexed on
2010/04/29
20:37 UTC
Read the original article
Hit count: 394
I'm somewhat new to objective-c and I'm not sure what the correct memory management for this code is.
const unsigned char * data =(const unsigned char *) [string UTF8String];
When I call free on data I get an error. Do I need to clean up after this call?
thanks!
© Stack Overflow or respective owner